<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
<!--
    -----------------
    Function Graphing
    -----------------
-->
	<TITLE>Sine Graph</TITLE>
</HEAD>
<SCRIPT LANGUAGE="JavaScript"><!--

var maxTheta = Math.PI;
var incTheta = (2 * Math.PI) / 100;

function GraphSineWave()
{
	var theta	 = -Math.PI;
	var x		 = 50;
	while(theta < maxTheta) {
		var y = Math.floor(Math.sin(theta)*100);
		if(y < 0) { // Plot on negative side of y axis
			y = Math.abs(y);
			// The empty part to the left of the curve
			var y1 = (100 - y);
			if(y1 > 0)
				document.write('<IMG SRC="../GRAFX/BLANK.GIF" HEIGHT=1 WIDTH='+y1+'>');
			// The extent of the curve
			document.write('<IMG SRC="../GRAFX/PIXEL.GIF" HEIGHT=1 WIDTH='+y+'>');
			// The graph axis
			document.writeln('<IMG SRC="../GRAFX/WHITEPIX.GIF" HEIGHT=1 WIDTH=1><BR>');
		} else { // Plot on positive size of y axis
			// The empty quadrant up to the axis
			document.write('<IMG SRC="../GRAFX/BLANK.GIF" HEIGHT=1 WIDTH=100>');
			// The graph axis
			document.write('<IMG SRC="../GRAFX/WHITEPIX.GIF" HEIGHT=1 WIDTH=1>');
			// The extent of the curve
			document.writeln('<IMG SRC="../GRAFX/PIXEL.GIF" HEIGHT=1 WIDTH='+y+'><BR>');
		}
		x -= 1;
		if(x == 0) {
			document.writeln('<IMG SRC="../GRAFX/X_AXIS.GIF" WIDTH=201 HEIGHT=1><BR>');
		}
		theta += incTheta;
	}
}
//-->
</SCRIPT>
<!--  Remaining text omitted -->
</HTML>